\(\int (a+b x) (a c-b c x)^2 \, dx\) [1029]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 17, antiderivative size = 38 \[ \int (a+b x) (a c-b c x)^2 \, dx=-\frac {2 a c^2 (a-b x)^3}{3 b}+\frac {c^2 (a-b x)^4}{4 b} \]

[Out]

-2/3*a*c^2*(-b*x+a)^3/b+1/4*c^2*(-b*x+a)^4/b

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 38, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 1, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.059, Rules used = {45} \[ \int (a+b x) (a c-b c x)^2 \, dx=\frac {c^2 (a-b x)^4}{4 b}-\frac {2 a c^2 (a-b x)^3}{3 b} \]

[In]

Int[(a + b*x)*(a*c - b*c*x)^2,x]

[Out]

(-2*a*c^2*(a - b*x)^3)/(3*b) + (c^2*(a - b*x)^4)/(4*b)

Rule 45

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps \begin{align*} \text {integral}& = \int \left (2 a (a c-b c x)^2-\frac {(a c-b c x)^3}{c}\right ) \, dx \\ & = -\frac {2 a c^2 (a-b x)^3}{3 b}+\frac {c^2 (a-b x)^4}{4 b} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.00 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.11 \[ \int (a+b x) (a c-b c x)^2 \, dx=c^2 \left (a^3 x-\frac {1}{2} a^2 b x^2-\frac {1}{3} a b^2 x^3+\frac {b^3 x^4}{4}\right ) \]

[In]

Integrate[(a + b*x)*(a*c - b*c*x)^2,x]

[Out]

c^2*(a^3*x - (a^2*b*x^2)/2 - (a*b^2*x^3)/3 + (b^3*x^4)/4)

Maple [A] (verified)

Time = 0.14 (sec) , antiderivative size = 37, normalized size of antiderivative = 0.97

method result size
gosper \(\frac {x \left (3 b^{3} x^{3}-4 a \,b^{2} x^{2}-6 a^{2} b x +12 a^{3}\right ) c^{2}}{12}\) \(37\)
default \(\frac {1}{4} b^{3} c^{2} x^{4}-\frac {1}{3} a \,b^{2} c^{2} x^{3}-\frac {1}{2} a^{2} c^{2} b \,x^{2}+a^{3} c^{2} x\) \(45\)
norman \(\frac {1}{4} b^{3} c^{2} x^{4}-\frac {1}{3} a \,b^{2} c^{2} x^{3}-\frac {1}{2} a^{2} c^{2} b \,x^{2}+a^{3} c^{2} x\) \(45\)
risch \(\frac {1}{4} b^{3} c^{2} x^{4}-\frac {1}{3} a \,b^{2} c^{2} x^{3}-\frac {1}{2} a^{2} c^{2} b \,x^{2}+a^{3} c^{2} x\) \(45\)
parallelrisch \(\frac {1}{4} b^{3} c^{2} x^{4}-\frac {1}{3} a \,b^{2} c^{2} x^{3}-\frac {1}{2} a^{2} c^{2} b \,x^{2}+a^{3} c^{2} x\) \(45\)

[In]

int((b*x+a)*(-b*c*x+a*c)^2,x,method=_RETURNVERBOSE)

[Out]

1/12*x*(3*b^3*x^3-4*a*b^2*x^2-6*a^2*b*x+12*a^3)*c^2

Fricas [A] (verification not implemented)

none

Time = 0.21 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.16 \[ \int (a+b x) (a c-b c x)^2 \, dx=\frac {1}{4} \, b^{3} c^{2} x^{4} - \frac {1}{3} \, a b^{2} c^{2} x^{3} - \frac {1}{2} \, a^{2} b c^{2} x^{2} + a^{3} c^{2} x \]

[In]

integrate((b*x+a)*(-b*c*x+a*c)^2,x, algorithm="fricas")

[Out]

1/4*b^3*c^2*x^4 - 1/3*a*b^2*c^2*x^3 - 1/2*a^2*b*c^2*x^2 + a^3*c^2*x

Sympy [A] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 46, normalized size of antiderivative = 1.21 \[ \int (a+b x) (a c-b c x)^2 \, dx=a^{3} c^{2} x - \frac {a^{2} b c^{2} x^{2}}{2} - \frac {a b^{2} c^{2} x^{3}}{3} + \frac {b^{3} c^{2} x^{4}}{4} \]

[In]

integrate((b*x+a)*(-b*c*x+a*c)**2,x)

[Out]

a**3*c**2*x - a**2*b*c**2*x**2/2 - a*b**2*c**2*x**3/3 + b**3*c**2*x**4/4

Maxima [A] (verification not implemented)

none

Time = 0.20 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.16 \[ \int (a+b x) (a c-b c x)^2 \, dx=\frac {1}{4} \, b^{3} c^{2} x^{4} - \frac {1}{3} \, a b^{2} c^{2} x^{3} - \frac {1}{2} \, a^{2} b c^{2} x^{2} + a^{3} c^{2} x \]

[In]

integrate((b*x+a)*(-b*c*x+a*c)^2,x, algorithm="maxima")

[Out]

1/4*b^3*c^2*x^4 - 1/3*a*b^2*c^2*x^3 - 1/2*a^2*b*c^2*x^2 + a^3*c^2*x

Giac [A] (verification not implemented)

none

Time = 0.31 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.16 \[ \int (a+b x) (a c-b c x)^2 \, dx=\frac {1}{4} \, b^{3} c^{2} x^{4} - \frac {1}{3} \, a b^{2} c^{2} x^{3} - \frac {1}{2} \, a^{2} b c^{2} x^{2} + a^{3} c^{2} x \]

[In]

integrate((b*x+a)*(-b*c*x+a*c)^2,x, algorithm="giac")

[Out]

1/4*b^3*c^2*x^4 - 1/3*a*b^2*c^2*x^3 - 1/2*a^2*b*c^2*x^2 + a^3*c^2*x

Mupad [B] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.16 \[ \int (a+b x) (a c-b c x)^2 \, dx=a^3\,c^2\,x-\frac {a^2\,b\,c^2\,x^2}{2}-\frac {a\,b^2\,c^2\,x^3}{3}+\frac {b^3\,c^2\,x^4}{4} \]

[In]

int((a*c - b*c*x)^2*(a + b*x),x)

[Out]

a^3*c^2*x + (b^3*c^2*x^4)/4 - (a^2*b*c^2*x^2)/2 - (a*b^2*c^2*x^3)/3